import 'package:flutter/material.dart';
import 'package:flutter_widget_from_html/flutter_widget_from_html.dart';
import 'package:get/get.dart';
import 'package:wallet_utils/color.dart';
import 'package:wallet_utils/ht_appbar.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:wallet_utils/text_style.dart';
import 'logic.dart';

class AgreementPage extends StatelessWidget {
  final logic = Get.put(AgreementLogic());
  final state = Get.find<AgreementLogic>().state;

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      backgroundColor: ColorManager.colorF4F5F6,
      appBar: htCommonAppbar(context, title: state.name),
      body: SingleChildScrollView(
        child: Container(
          margin: EdgeInsets.only(top: 20.w,bottom: 20.w,left: 16.w,right: 16.w),
          child: HtmlWidget(
            state.content ?? '',
            textStyle: TextStyleUtils.style999999(fontSize: 13.sp),
          ),
        ),
      ),
    );
  }
}
